package com.xuzhen.designPattern.mediator.one;

/**
 * 中介者设计模式
 *   
 */
public class Test {
	public static void main(String[] args) {
		IntelligenceMediator mediator = new IntelligenceMediator();

		Renter zhangshang = new Renter(mediator);
		Landlord lishi = new Landlord(mediator);

		mediator.setLandlord(lishi);
		mediator.setRenter(zhangshang);

		zhangshang.sendMessage("带空调、独卫和阳台的25平米的房间多少钱？");
		lishi.sendMessage("800元每月，水费15元，物业费15元，电费0.8元每度.");
	}
}
